DEMO: When a triangle rotates about the origin, it's distance from the origin is preserved. That means, each point on the triangle stays the same distance from the origin as the triangle rotates.

  • Click on the triangle four times to move it one full 360 degree rotation.
  • After you have seen the full rotation, click Submit and Next to continue the lesson.

To navigate the page using the TAB key, first press ESC to exit the code editor.

# stage.create_grid_overlay(line_separation, "line_color") stage.create_grid_overlay(50, "grey") sprite = codesters.Sprite("triangle", 100, 50) sprite.set_speed(1)
  • Run Code
  • Submit Work
  • Next Activity
  • Show Console
  • Reset Code Editor
  • Codesters How To (opens in a new tab)